<?php
namespace Home\Controller;
use Think\Controller;

class ChartsController extends Controller {
    public function chart() {       
        $this->display('qu_ren');
    }
    public function soumodel() {       
        $wd = $_POST['keyword'];
        $keywords = $wd;   
        $company_model = M('Modelname');  
        $res = $company_model->where("name like '%".$keywords."%' ")->limit(10)->select();
        foreach($res as $v){
            $suggestions[]= array('title' => $v['name']);
        }
        echo json_encode(array('data' => $suggestions));
    }
    public function tiaozhuan() {       
        $modelname = $_POST['modelname'];
        $keywords = $modelname;   
        $company_model = M('Modelname');  
        $where = array();
        $where['name'] = array('eq',"$keywords");
        $res = $company_model->where($where)->find();
        // $this->display("$res.url");
        // $this->success("跳转中...", U("$res.url"));
        if($res>0){
            echo json_encode($res);
        }else{
            echo json_encode(0);
        }
        
    }
    public function shequ() {
        $this->display();
    }
    public function jiedao() {
        $this->display();
    }
    public function qu_ren() {
        $this->display();
    }
    public function qu_che() {
        $this->display();
    }
    public function qu_fang() {
        $this->display();
    }
    public function qu_danwei() {
        $this->display();
    }
    public function jiedao_ren() {
        $this->display();
    }
    public function jiedao_che() {
        $this->display();
    }
    public function jiedao_fang() {
        $this->display();
    }
    public function jiedao_danwei() {
        $this->display();
    }
    public function shequ_ren() {
        $this->display();
    }
    public function shequ_che() {
        $this->display();
    }
    public function shequ_fang() {
        $this->display();
    }
    public function shequ_danwei() {
        $this->display();
    }
}
